﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Site.master" AutoEventWireup="true"
    CodeFile="MonthSheet.aspx.cs" Inherits="Report_MonthSheet" %>

<asp:Content ID="Content1" ContentPlaceHolderID="HeadContent" runat="Server">
    <script type="text/javascript" src="../My97DatePicker/WdatePicker.js"></script>
    <link href="../My97DatePicker/skin/WdatePicker.css" type="text/css" rel="Stylesheet" />
    <style>
        .HasRemark {
            color:crimson
        }
        .HasnotRemark {
            color:cornflowerblue
        }
    </style>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" runat="Server">
    <h2>
        月表</h2>
    <div class="searchcondition">
        <table class="searchtb">
            <tr>
                <td>
                    月份
                </td>
                <td>
                    <asp:DropDownList ID="DropDownList1" runat="server"  >
                        <asp:ListItem Value="0">当月</asp:ListItem>
                        <asp:ListItem Value="1">前一月</asp:ListItem>
                    </asp:DropDownList>
                </td>
               
            </tr>
        </table>
        <div>
            <asp:Button ID="Button1" runat="server" Text="查询" CssClass="searchbutton" CausesValidation="True"
                OnClick="Button1_Click" /></div>
    </div>
    <div>提示：鼠标移至价格处悬停，可见报单备注；在订单编号处悬停，可见下单具体时间；在说明处悬停，可见具体说明</div>
    <asp:GridView ID="GridView1" runat="server" AutoGenerateColumns="False" DataKeyNames="订单编号"
        CssClass="commongv">
        <Columns>
            <asp:TemplateField HeaderText="订单编号" SortExpression="订单编号">               
                <ItemTemplate>
                    <asp:Label ID="Label2" runat="server" Text='<%# Bind("订单编号") %>' ToolTip='<%# Bind("下单时间","下单时间:{0:yyyy-MM-dd}") %>'></asp:Label>
                </ItemTemplate>
            </asp:TemplateField>
            <asp:BoundField DataField="CompanyID" HeaderText="公司编号" SortExpression="CompanyID" />
            <asp:BoundField DataField="公司英文名" HeaderText="公司英文名" SortExpression="公司英文名" />
            <asp:BoundField DataField="公司中文名" HeaderText="公司中文名" SortExpression="公司中文名" />
            <asp:BoundField DataField="委托类型" HeaderText="委托类型" SortExpression="委托类型"/>
            <asp:BoundField DataField="注册地" HeaderText="注册地" SortExpression="注册地" />
            <asp:TemplateField HeaderText="成交价" SortExpression="成交价格">
                <ItemTemplate>
                    <asp:Label ID="Label1" runat="server" Text='<%# Bind("成交价格", "{0:0}") %>' ToolTip='<%# Bind("备注","备注:{0}") %>'></asp:Label>
                </ItemTemplate>
            </asp:TemplateField>
            <asp:BoundField DataField="币种" HeaderText="币种" SortExpression="币种" />
            <asp:BoundField DataField="分行" HeaderText="分行" SortExpression="分行" />
            <asp:TemplateField HeaderText="备注">
                <ItemTemplate>
                    
                    <asp:HyperLink ID="HyperLink1" runat="server" Text='说明'
                    ForeColor='<%# Eval("说明").ToString()==""? System.Drawing.Color.RoyalBlue: System.Drawing.Color.Red %>' NavigateUrl='<%# Bind("订单编号", "AddOrderRemark.aspx?orderId={0}") %>' ToolTip='<%# Bind("说明","说明:{0}") %>'></asp:HyperLink>
                  
                </ItemTemplate>
            </asp:TemplateField>
        </Columns>
    </asp:GridView>    
    
    

    <asp:GridView ID="GridView2" runat="server" CssClass="commongv">
    </asp:GridView>
    
    

    
    
    

    <asp:SqlDataSource ID="SqlDataSource2" runat="server" ConnectionString="<%$ ConnectionStrings:KOONCRMDB %>"
        SelectCommand="SELECT [BranchID], [BranchName] FROM [Branch] WHERE ([Status] = @Status)">
        <SelectParameters>
            <asp:Parameter DefaultValue="0" Name="Status" Type="Int16" />
        </SelectParameters>
    </asp:SqlDataSource>
    <asp:ObjectDataSource ID="ObjectDataSource1" runat="server" 
        SelectMethod="GetDelegates" TypeName="Koonsoft.HYCRM.BLL.DelegateBLL">
    </asp:ObjectDataSource>
    <asp:SqlDataSource ID="SqlDataSource3" runat="server" 
        ConnectionString="<%$ ConnectionStrings:KOONCRMDB %>" 
        SelectCommand="SELECT [RegionName], [RegionID] FROM [Region]">
    </asp:SqlDataSource>
    <asp:SqlDataSource ID="SqlDataSource4" runat="server" 
        ConnectionString="<%$ ConnectionStrings:KOONCRMDB %>" 
        SelectCommand="SELECT [Name], [EmpolyeeID] FROM [Empolyee] WHERE ([Status] = @Status) ORDER BY [Name]">
        <SelectParameters>
            <asp:Parameter DefaultValue="0" Name="Status" Type="Byte" />
        </SelectParameters>
    </asp:SqlDataSource>
</asp:Content>
